<?php

namespace app\model;
use app\util\Tools;
class TaskRecord extends Base
{
    protected $autoWriteTimestamp = true;
    protected $resultSetType = 'collection';
    protected $updateTime = 'updateTime';
    protected $createTime = 'addTime';


    public function getStatusTextAttr($value, $data) {
        $status = ['1' => '已发放任务', '2' => '未发放任务'];
        return isset($status[$data['status']])?$status[$data['status']]:'未知';
    }
}